<!DOCTYPE html>
<html ng-app>
	<head>
		<title>Using AngularJS Directive and Data Binding</title>
	</head>
	<body>
		<div ng-controller="SimpleController">

			<input type="text" ng-model="name" /> {{name}}
			<br />
			<br />
			<ul>	
				<li ng-repeat="cust in customers | filter:name | orderBy:'city'">
					{{cust.name}} - {{cust.city}}
				</li>
			</ul>
			
		</div>
		
		<script type="text/javascript" src="angular.min.js"></script>

		<script>
			function SimpleController($scope) {
				$scope.customers = [
					{name:'John Smith', city:'Phoenix'}, 
					{name:'John Doe', city:'New York'}, 
					{name:'Jane Doe', city:'San Francisco'}
					]
			}
		</script>
	</body>
</html>